package com.xingzhe.base.exception;


public class XingZhePlusException extends RuntimeException{
    private String errMessage;

    public XingZhePlusException(){
        super();
    }
    public XingZhePlusException(String message){
        super(message);
        this.errMessage=message;
    }

    public String getErrMessage() {
        return errMessage;
    }

    public static void cast(String message){
        throw new XingZhePlusException(message);
    }

    public static void cast(CommonError commonError){
        throw new XingZhePlusException(commonError.getErrMessage());
    }
}
